<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<title>jQuery双日历日期区间选择插件daterangepicker - JS代码网</title> 
		<script type="text/javascript" src="../js/jquery-1.3.1.min.js"></script>
		<script type="text/javascript" src="../js/jquery-ui-1.7.1.custom.min.js"></script>
		<script type="text/javascript" src="../js/daterangepicker.jQuery.js"></script>
		<link rel="stylesheet" href="../css/ui.daterangepicker.css" type="text/css" />
		<link rel="stylesheet" href="../css/redmond/jquery-ui-1.7.1.custom.css" type="text/css" title="ui-theme" />
		<script type="text/javascript">	
			$(function(){
				  $('#rangeA').daterangepicker({
					presetRanges:[
						//{text:'最近一周', dateStart:'yesterday-7days', dateEnd:'yesterday' },
						//{text:'最近一月', dateStart:'yesterday-1month', dateEnd:'yesterday' },
						//{text:'最近一年', dateStart:'yesterday-1year', dateEnd:'yesterday' }
					],
					presets:{
						dateRange:'自定义时间'
					},
					rangeStartTitle:'起始日期',
					rangeEndTitle:'结束日期',
					nextLinkText:'下月',
					prevLinkText:'上月',
					doneButtonText:'确定',
					cancelButtonText:'取消',
					earliestDate:'',
					latestDate:Date.parse('today'),
					constrainDates:true,
					rangeSplitter:'-',
					dateFormat:'yy-mm-dd',
					closeOnSelect:false,
					onOpen:function(){
						$('.ui-daterangepicker-dateRange').click().parent().hide();
					}}
				); 
		});
		</script>
		
		<!-- from here down, demo-related styles and scripts -->
		<style type="text/css">
			body { font-size: 62.5%; }
			input {width: 196px; height: 1.1em; display:block;}
		</style>
	</head>
	<body>	

		<input type="text" value="" id="rangeA" />			
		
	</body>
</html>
